Release v0.7.9 — aCCF validity mask, speed filtering & physics updates - #65
Merged
Conversation
Waypoints outside the aCCF validity region (pressure above threshold) now get NaN instead of 0.0 in ATR_20_O3, ATR_20_CH4, ATR_20_H2O columns. This distinguishes 'not applicable / physically invalid' from 'actually zero'. Downstream GWP summation is unaffected because gwp.py already uses .fillna(0.0) before summing.
Add v_stall_cas(mass, config) -> float | None to the BaseBADAAdapter protocol and implement it on _PyBADAAdapterBase, delegating to pyBADA's flightEnvelope.VStall. Returns None gracefully when CLmax data is unavailable. Also adds mypy ignore_errors for tests/ and scripts/ overrides, aligning with the Makefile scope (mypy src/pyneats/ only). Closes: AXM-812
Add filter_low_speed_points() in speed_filter module that removes trajectory points with TAS below the BADA adapter's stall speed. Follows the same pattern as the existing altitude_filter. Closes: AXM-813
Call filter_low_speed_points after adapter resolution in run_by_bada_version. On any filter failure, degrade gracefully and proceed with unfiltered data. Extract _build_result from inline guardrail+efficiency+output code for testability. Closes: AXM-814
…ther The speed filter was operating on the FlightWithWeather object while the downstream performance pipeline iterated on the separate `df` DataFrame, making the filter a no-op. Refactor filter_low_speed_points to accept/return pd.DataFrame so it directly modifies the data used by the TEM equation. Update all tests to match the new API. Refs: AXM-813, AXM-814
…al., 2025) Updated CO2_AGWP_COEFF_WM2YR_PER_KG values: - H20: 24.16e-15 → 24.12e-15 - H50: 47.57e-15 → 47.50e-15 - H100: 74.36e-15 → 74.24e-15
pybada >=0.1.11 now supports standard pip/uv install, removing the need for the --no-deps --ignore-requires-python workaround. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add max_pressure_level parameter (default 500 hPa) to TrajectoryParserParams. NeatsTrajectoryParser.run() now checks Flight.level.min() after building the Flight object and rejects trajectories that never reach high enough altitude for contrail analysis. Includes 4 new tests in TestParsingGuardrailPressureLevel.
… scaling of the accf formula
The LICENSE file was renamed to LICENSE.md but pyproject.toml still referenced the old name, breaking hatchling builds. Also fixes two ruff lint errors (import sort + blank line whitespace).
Pre-commit used ruff v0.9.2 while CI ran v0.14.11, causing formatting discrepancies on neats_default_parameters.py.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR bundles several improvements to the NEATS pipeline covering data quality, physical accuracy, and robustness of the performance model.
Changes
🐛 Bug Fixes
NaNinstead of0.0inATR_20_O3,ATR_20_CH4,ATR_20_H2Ocolumns. This properly distinguishes physically invalid data from actual zero values. Downstream GWP summation is unaffected (.fillna(0.0)before summing).CO2_AGWP_COEFF_WM2YR_PER_KGto latest AirClim values (Dahlmann et al., 2025):24.12e-15,47.50e-15,74.24e-15for H20/H50/H100.✨ Features
speed_filtermodule removes trajectory points with TAS below BADA's stall speed (VStall), preventing numerical instability in the TEM equation. Integrates gracefully in the performance pipeline with fallback on failure.v_stall_cason BADA adapters — Exposed stall speed computation onBaseBADAAdapter, delegating to pyBADA'sFlightEnvelope.VStall.max_pressure_levelparameter (default 500 hPa) inTrajectoryParserParams. Flights that never reach sufficient altitude for contrail analysis are rejected early.🔧 Maintenance
pyproject.tomldependency (>=0.1.11).